﻿#include "genlib.h"
#include "simpio.h"
#include "graph.h"
#include "pqueue.h"
#include "PrimKruskal.h"
#include "FloydWarshall.h"
#include "knapsack.h"

/* Main application */
int main() {
	int choice;
	
	while (TRUE) {
		system("cls");
		printf("-- Problem types --\n\n");
		printf(" 1. Tree (MST)\t\t algorithms: Prim's, Kruskal's\n");
		printf(" 2. Graphs\t\t algorithms: Warshall's, Floyd's\n");
		printf(" 3. Knapsack problem\n");
		printf(" 0. Quit\n");
		printf("\n => ");
		choice = GetInteger();
		switch (choice) {
			case 1: runMst();			break;
			case 2: runGraph();		break;
			case 3: runKnapsack();	break;
			default: return;
		}
	}
}